//
//  ImageDHViewController.swift
//  UI
//
//  Created by admin on 14/9/19.
//  Copyright (c) 2014年 sinosun. All rights reserved.
//

import UIKit

class ImageDHViewController: UIViewController {



    @IBOutlet var imageview: UIImageView!





    override func viewDidLoad() {
        
        super.viewDidLoad()
        self.title = "图片动画"
        var image_urls = ["one","two","three","four"]
        var images = [UIImage]()
        for var i=0; i<image_urls.count; ++i{
           var image = UIImage(named: image_urls[i])
           images.append(image)
        }
        
        
        
        
        
        
//        // Do any additional setup after loading the view.
        imageview.animationDuration = 1
        imageview.animationImages = images
        imageview.startAnimating()
    }

    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
        // Dispose of any resources that can be recreated.
    }
    

    /*
    // MARK: - Navigation

    // In a storyboard-based application, you will often want to do a little preparation before navigation
    override func prepareForSegue(segue: UIStoryboardSegue!, sender: AnyObject!) {
        // Get the new view controller using segue.destinationViewController.
        // Pass the selected object to the new view controller.
    }
    */

}
